const http=require("http");

var server=http.createServer();
server.on("request",(req,res)=>{
	var book={name:'harrypolt',price:23.45};
	res.setHeader("Content-Type","application/json");
	
	res.end(JSON.stringify(book));
})
server.listen(5002,function(err){
	if(!err){
		console.log("http server start in 5002");
	}
});